/*
 *说明：NSCG信息表 首页脚本
 *
 *@author liuxun 2012-03-13
*/

var opeForm;
var grid;

$(function(){
	opeForm = $('#opeForm');

	grid=$('#listTable').datagrid({
		frozenColumns:[[
            //{title:'选择',field:'ck',checkbox:true}
		]],
		columns:[[

            {title:'策略类型',field:'policy_type_decode',align:'center',width:120},

            {title:'策略名称',field:'policy_name',align:'center',width:120}

        ]],
		pagination:false,
		singleSelect: false
	});

	queryOperation();
});

//翻页时自动调用此函数
function onLoadPrev(msg){
	var queryParams=grid.datagrid('options').queryParams;
	queryParams['firstQuery']=false;
}

//查询操作
function queryOperation(){
	var params = opeForm.serializeObject();
	grid.datagrid("options").pageNumber = 1;
	grid.datagrid({
		url: 'D_POLICYGRP_POLICY!showSelectPolicysList.do',
		queryParams: jQuery.extend({}, params, {'firstQuery': true})
	});
}